package com.pctx.bibaregisterlogin.service.impl;

import com.pctx.bibaregisterlogin.dao.CompanyMapper;
import com.pctx.bibaregisterlogin.pojo.Company;
import com.pctx.bibaregisterlogin.service.CompanyService;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created by chason on 2018/3/12.11:48
 */
@Service("companyService")
public class CompanyServiceImpl implements CompanyService {
    @Autowired
    private CompanyMapper companyMapper;

    @Override
    public Company getByCompanyNo(String companyNo) throws Exception {
        if (StringUtils.isEmpty(companyNo))
            return null;

        return companyMapper.getByCompanyNo(companyNo);
    }
}
